﻿<%@ Page Language="C#" MasterPageFile="~/Views/Shared/Site.Master" Inherits="System.Web.Mvc.ViewPage" %>

<asp:Content ID="indexContent" ContentPlaceHolderID="MainContent" runat="server">
<% if (Request.IsAuthenticated) { %>
    Hello, <%: User.Identity.Name %>
    <% using (Html.BeginForm("Logout", "Login", FormMethod.Post, new { id = "logoutForm" })) { %>
        <%: Html.AntiForgeryToken() %>
        <a href="javascript:document.getElementById('logoutForm').submit()">Log off</a>
    <% } %>
<% } else {%>
    <%: Html.ActionLink("Login","Index","Login") %>

<% } %>
     
</asp:Content>
